import request from '@/utils/request'

export function findAllRole(data,params) {
  return request({
    url: '/role/findAllRole',
    method: 'post',
    data,
    params
  })
}

export function addRole(data) {
  return request({
    url: '/role/addRole',
    method: 'post',
    data
  })
}

export function updateRole(data) {
  return request({
    url: '/role/updateRole',
    method: 'post',
    data
  })
}

export function deleteRole(data) {
  return request({
    url: '/role/deleteRole',
    method: 'post',
    data
  })
}

export function findPrivileges(params) {
  return request({
    url: '/role/findPrivileges',
    method: 'get',
    params
  })
}

export function findRole(params) {
  return request({
    url: '/role/findRole',
    method: 'get',
    params
  })
}
